import Vue from 'vue'
import VueRouter from 'vue-router'
import Home from '../views/Home.vue'
import FriendChat from "../views/chat/FriendChat.vue"

Vue.use(VueRouter)

const routes = [
  {
    path: '/',
    name: 'Login',
    hidden: true,
    component: () => import('../views/Login')
  },
  {
      path: '/home',
      name: 'Home',
      component: Home,
      hidden:true,
	  children: [
		  {
		    path: '/chat',
		    name: '聊天界面',
		    hidden: true,
		    component: FriendChat
		  }
	  ]
    },
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
